using System.Globalization;
using NUnit.Framework;
using ResourceBlender.Express;

namespace ResourceBlender.Tests
{
    [TestFixture]
    public class UtilsTests
    {
        [TestCase("he-IL", Result = "iw_IL")]
        [TestCase("zh-Hans", Result = "zh_CN")]
        [TestCase("zh-CHS", Result = "zh_CN")]
        [TestCase("zh-Hant", Result = "zh_TW")]
        [TestCase("zh-CHT", Result = "zh_TW")]
        [TestCase("sv-SE", Result = "sv_SE")]        
        public string CanConvertDotNetCulture2JavaCulture(string dotNetCultureName)                        
        {
            // Check if culture name is valid
            var info = new CultureInfo(dotNetCultureName);

            // Invoke the method to test
            string javaCultureName = Utils.DotNetCulture2JavaCulture(info.Name);

            // Return the result
            return javaCultureName;
        }
    }
}